from django.contrib.auth import views as login
from django.urls import path

# urlpatterns = [
#     path('login/',login,{'template_name':'users/login.html'},name='login'),
#
# ]


from django.urls import path
from django.contrib.auth.views import LoginView
from . import views
app_name = 'users'  # 这行很重要
urlpatterns = [
    path('login/', LoginView.as_view(template_name='users/login.html'), name='login'),
    path('logout/', views.logout_view,name='logout'),
    ## 注册逻辑
    path('register/', views.register, name='register'),
]